package com.abe.mvp.contact;

public class SocketContact {

	public interface View {
		/** 连接成功 */
		void onSocketConnectSuccess();

		/** 关闭成功 */
		void onSocketCloseSuccess();

		/** 发送消息 */
		void onSocketSendDataSuccess();

		/** 接收消息 */
		void onSocketReceiveDataSuccess(String receiveMsg);

		/** 错误 */
		void onSocketError(String errorMsg);
	}

	public interface Model {

		public interface ISocketBack {
			public void onResult(int code, Object data, String errorMSG);
		}

		/** 开启Socket */
		void openSocket(String IP, int Port);

		/** 下发命令 */
		void sendSocketCommand(String msg);

		/** 关闭Socket */
		void closeSocket();

		/** 检查socket状态 */
		void checkScoket();
	}

	public interface Presenter {
		/** 开启Socket */
		void openSocket(String IP, int Port);

		/** 下发命令 */
		void sendSocketCommand(String msg);

		/** 关闭Socket */
		void closeSocket();

		/** 检查socket状态 */
		void checkScoket();
	}
}
